The present invention relates to data storage, and more particularly, to reading data from tape selectively using single and/or multi-cut and paste (C/P) reconstructive error recovery procedure (ERP) which relies on a history of error to reduce backhitches during error burst scenarios.
Tape and optical storage devices use very powerful error correction codes, such as product codes or concatenated codes, in conjunction with interleaving to provide a very high degree of data integrity. These error correction schemes typically use two error correction codes (ECCs) as component codes. Two important burst-error performance measures for tape storage systems protected by these schemes are: 1) lateral width of an erroneous stripe which is still capable of being corrected (this is also known as “broken track correction” capability), and 2) longitudinal width of an erroneous stripe that is still capable of being corrected. A “broken” track generally refers to a track that cannot be read correctly due to a problem on the media itself and/or a problem with the readback channel, e.g., as a channel that does not detect data correctly because of alignment or some systematic problem with the head.
Magnetic tapes may store data in the form a “data sets” or files. Each data set is encoded using interleaved sets of codewords that are organized into an ECC-encoded matrix of size M bytes×N bytes (M×N) and then written to tape as shown in FIG. 1, according to the prior art. There are two levels of encoding within this matrix 150. The first level of encoding utilizes the matrix rows 102. Each row 102 of the matrix contains C1-ECC row parity 106, which adds p-bytes of C1-ECC to the n-bytes of user data (e.g., N=n+p bytes). The second level of encoding, C2-ECC column parity 108, adds q-bytes of C2-ECC to each matrix column 104. For example, if q=12, then adding 12 bytes of C2-ECC would add 12 rows to the matrix 150 (e.g., M=m+q bytes).
However, many temporary errors may occur during reading of the data (data sets) from the tape media. One such condition is called a “temp burst” or “error burst” (comprising a plurality of errors or temporary errors within a predetermined distance on the magnetic tape). Under an error burst condition, a tape drive may not be able to correct all errors encountered while reading the data from the tape in a predetermined amount of time, and reports these errors as one or more permanent errors. For example, when the data set is read from the tape in a high error rate condition, C1/C2 ECC is not capable of correcting the read data. For example, in some approaches, C1-encoding is capable of correcting 10 bytes of error, and C2-encoding is capable of correcting 20 bytes of error. If the error bytes exceed this correction power, then data cannot be read from the tape. In this scenario, the tape drive will then attempt ERP to read the data set from the tape again with a different hardware setting (e.g., changing the tape speed). ERP repeats until C1/C2-encoding is able to correct the data or until the ERP retry count exceeds a threshold. If the retry count exceeds the threshold, then the tape drive will report a permanent error for the read operation.
When an error burst is encountered while reading data from the magnetic tape, there are several different methods of attempting to handle the error burst. One method is “Reconstructive Error Recovery Procedure (ERP) Using Reserved Buffer,” which is described in more detail in U.S. patent application Ser. No. 13/676,477, filed Nov. 14, 2012, which has been incorporated by reference. This method uses a reconstructive ERP to reduce backhitches during error burst scenarios, and is referred to herein as C/P ERP Single.
Another such method is referred to as an “Iterative Cut and Paste Error Recovery Procedure” (C/P ERP Multi), which is described in more detail in U.S. patent application Ser. No. 13/676,493, filed Nov. 14, 2012, which has been incorporated by reference. This method attempts to solve burst reading errors for a tape drive reading a magnetic tape. However, the C/P ERP Multi uses a dedicated buffer area of a predetermined size, which is allocated regardless of other performance concerns (such as whether the tape drive has detected an error burst or not). Therefore, this usage of the dedicated buffer causes performance degradation for normal reading.
C/P ERP Multi typically utilizes a ring buffer of a type known in the art. The tape drive has a buffer memory which is divided and allocated to each segment and is referred to as a ring buffer because data is stored in the buffer from a starting point to an end point, and when more data needs to be stored, the starting point is again utilized (possibly overwriting data already stored therein). A tape drive reads/writes the data from/to magnetic tape media in units referred to as data sets and stores each data set into each segment. Segments are filled from top to bottom and back to top, repeatedly.
C/P ERP Multi improves performance under an error burst condition; however, the procedure utilizes a portion of the reserved buffer area. The procedure divides the ring buffer into two portions and uses one of these portions for storing data during the C/P ERP Multi procedure. The other portion of the ring buffer remains accessible by the tape drive for normal operation (reading/writing). As a result, the normal or typical ring buffer size is reduced and the ordinary streaming read performance (read performance that is possible when no error burst occurs) is degraded.
The two methods of C/P ERP (single cut/paste or multi-cut/paste) are available to conventional tape drives and must be selected by the tape drive before reading data. The drive must examine dynamic recovery performance criteria to determine which technique, C/P ERP Multi or C/P Single, will be the more effective choice. In configuring the drive for C/P ERP Multi operation, the drive may choose a buffer segmentation ratio based on dynamic performance criteria. Dynamically allocating a ring buffer is described in more detail in U.S. patent application Ser. No. 13/943,674, filed Jul. 16, 2013, which has been incorporated by reference.
However, in a typical tape drive, there is no ability to intelligently choose between C/P ERP Single and C/P ERP Multi when reading data from a medium, and instead the tape drive reacts to error burst conditions.